<template>
  <div class="w-full px-2 mt-1">
    <div class="font-bold text-[18px] mb-1">热门精选</div>
    <div class="w-full flex flex-wrap justify-between items-start">
      <template v-for="item in houseList" :key="item.data.houseId">
        <template v-if="item.discoveryContentType === 9">
          <homeHouseV9 :data="item.data"></homeHouseV9
        ></template>
        <template v-else-if="item.discoveryContentType === 3">
          <homeHouseV3 :data="item.data"></homeHouseV3>
        </template>
      </template>
    </div>
    <div
      class="text-gray-400 text-sm text-center mt-1 mb-1"
      v-show="!isHashHouseList"
    >
      —— 已经滚动到底部啦 ——
    </div>
  </div>
</template>
<script setup>
import useHomeStore from '@/stores/modules/home'
import homeHouseV3 from '@/components/home-house-v3/index.vue'
import homeHouseV9 from '@/components/home-house-v9/index.vue'
import { storeToRefs } from 'pinia'
const homeStore = useHomeStore()
const { isHashHouseList } = storeToRefs(homeStore)
const { houseList } = storeToRefs(homeStore)
</script>
<style lang="scss" scoped></style>
